package com.wn.demo02;

/**
 * @author yellow Docter
 * @date 2024 -06-17
 * @desc
 */
public class Demo01 {

    public static void main(String[] args) {

        Demo01 demo01 = new Demo01();
        String abc = demo01.toUpperStr("abc", x -> x.toUpperCase());
        System.out.println("abc = " + abc);

    }

    //函数式接口 可以用于参数传递
    public String toUpperStr(String str,MyFunc01 myFunc){
        return myFunc.getValue(str);
    }

}
